<!DOCTYPE html>
<html>
<head>
    <title>项目新建</title>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">
    <!-- Bootstrap -->
    <link rel="stylesheet" href="../../plugins/bootstrap/dist/css/bootstrap.min.css">
    <link rel="stylesheet" href="../../plugins/bootstrap-table/dist/bootstrap-table.min.css">
    <link rel="stylesheet" href="../../plugins/bootstrap-treeview/dist/css/bootstrap-treeview.min.css">
    <!-- Bootstrap Datetimepicker -->
    <link rel="stylesheet" href="../../plugins/bootstrap-datetimepicker/dist/css/bootstrap-datetimepicker.min.css">
    <!-- Font Awesome -->
    <link rel="stylesheet" href="../../css/font-awesome.min.css">
    <link rel="stylesheet" href="../../plugins/bootstrap-validator/dist/css/bootstrapValidator.min.css">
    <!-- Theme style -->
    <link rel="stylesheet" href="../../css/AdminLTE.min.css">
    <link rel="stylesheet" href="../../plugins/jquery-treegrid/jquery.treegrid.min.css">
    <link rel="stylesheet" href="../../plugins/ztree/css/metroStyle/metroStyle.css">
    <link rel="stylesheet" href="../../css/main.css">
    <!-- Select2 -->
    <link rel="stylesheet" href="../../plugins/select2/select2.min.css">
    <link rel="stylesheet" href="../../css/modules/project/newproject.css">

    <style>
        .layui-layer-page .layui-layer-content {
            /*overflow: hidden;*/
        }

        /* 责任人弹框数据容器 高度：500-42-80 */
        .layui-layer-content .data-pane {
            /*height: 378px;*/
            overflow: auto;
        }

        .layui-layer-content .btn-pane {
            padding: 10px;
            /*position: absolute;*/
            /*width: 100%;*/
            /*margin-left: -20px;*/
            /*bottom: 17px;*/
            /*text-align: center;*/
        }

        .layer-content {
            padding-top: 20px;
            background-color: #fff;
            box-sizing: border-box;
        }

        .layer-inp-cell {
            margin-bottom: 10px;
            text-align: center;
        }

        .new-project-wrapper .form-control {
            background-color: #fff;
        }
        /*select2插件选中元素颜色*/
        .select2-container--default .select2-selection--multiple .select2-selection__choice {
            color: #333;
        }
    </style>
</head>
<body class="page-wrapper">
<div id="rrapp" class="new-project-wrapper" v-cloak style="min-width: 960px;">
    <div v-show="showList">
        <div class="row">
            <div class="col-xs-12">
                <div class="box box-primary">
                    <div class="box-body">
                        <div class="panel np-form-container">
                            <form class="form-horizontal np-form" id="np-form">
                                <div class="form-group">
                                    <div class="col-sm-6">
                                        <div class="col-sm-4 control-label">项目名称：</div>
                                        <div class="col-sm-8">
                                            <input type="text" class="form-control" v-model="projectEntity.projectName"
                                                   placeholder="项目名称" name="projectName">
                                            <!--<input type="hidden" v-model="projectEntity.projectStatus">-->
                                        </div>
                                    </div>
                                    <div class="col-sm-6">
                                        <div class="col-sm-4 control-label">项目编号：</div>
                                        <div class="col-sm-8">
                                            <input type="text" class="form-control"
                                                   v-model="projectEntity.projectNumber" placeholder="项目编号"
                                                   name="projectNumber">
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <div class="col-sm-6">
                                        <div class="col-sm-4 control-label">项目所属区域：</div>
                                        <div class="col-sm-8">
                                            <select  class="form-control select2" id="applicant" multiple="multiple"
                                                     data-placeholder="选择所属区域"
                                                     style="width: 100%;">
                                            </select>

                                        </div>
                                    </div>
                                    <div class="col-sm-6">
                                        <div class="col-sm-4 control-label">电压类型：</div>
                                        <div class="col-sm-8">
                                            <select class="form-control" v-model="projectEntity.voltageType"
                                                    name="voltageType">
                                                <option v-for="(item,index) in vTypeList" :value="item.typeCode">
                                                    {{item.typeName}}
                                                </option>
                                            </select>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <div class="col-sm-6">
                                        <div class="col-sm-4 control-label">项目申请方：</div>
                                        <div class="col-sm-8">
                                            <select  class="form-control select2" id="projectApplicant" multiple="multiple"
                                                     data-placeholder="选择项目申请方"
                                                     style="width: 100%;">
                                            </select>
                                        </div>
                                    </div>
                                    <div class="col-sm-6">
                                        <div class="col-sm-4 control-label">项目申报时间：</div>
                                        <div class="col-sm-8">
                                            <input type="text" ref="input1" class="form-control" id="inp-date-start"
                                                   @blur="inputFunc" v-model="projectEntity.projectTime"
                                                   placeholder="项目申报时间" name="projectTime">
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <div class="col-sm-6">
                                        <div class="col-sm-4 control-label">项目类型：</div>
                                        <div class="col-sm-8">
                                            <select class="form-control" v-model="projectEntity.projectType"
                                                    name="projectType" disabled="true">
                                                <option v-for="(item,index) in pTypeList" :value="item.typeCode">
                                                    {{item.typeName}}
                                                </option>
                                            </select>
                                           <!-- <input type="text" class="form-control" v-model="projectEntity.projectType" name="projectType" :value="item.typeCode" readonly/>-->

                                        </div>
                                    </div>
                                    <div class="col-sm-6">
                                        <div class="col-sm-4 control-label">项目级别：</div>
                                        <div class="col-sm-8">
                                            <!--<input type="text" class="form-control" v-model="projectEntity.projectLevel" placeholder="项目级别">-->
                                            <select class="form-control" v-model="projectEntity.projectLevel"
                                                    name="projectLevel">
                                                <option v-for="(item,index) in pLevelList" :value="item.levelCode">
                                                    {{item.levelName}}
                                                </option>
                                            </select>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <div class="col-sm-6">
                                        <div class="col-sm-4 control-label">项目流程模板：</div>
                                        <div class="col-sm-8">
                                            <select class="form-control" v-model="projectEntity.templateId">
                                                <option v-for="(item,index) in mTypeList" :value="item.id">
                                                    {{item.templateName}}
                                                </option>
                                            </select>
                                        </div>
                                    </div>
                                    <div class="col-sm-6">
                                        <div class="col-sm-4 control-label">项目经理：</div>
                                        <div class="col-sm-8">
                                            <select class="form-control" v-model="projectEntity.projectManager">
                                                <option v-for="(item,index) in pmList" :value="item.pmId">
                                                    {{item.pmName}}
                                                </option>
                                            </select>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <div class="col-sm-6">
                                        <div class="col-sm-4 control-label">项目开始时间：</div>
                                        <div class="col-sm-8">
                                            <input type="text" ref="input2" class="form-control" id="inp-start-date"
                                                   @blur="inputStartDateFunc" v-model="projectEntity.projectStartTime"
                                                   placeholder="项目开始时间" name="projectTime">
                                        </div>
                                    </div>
                                    <div class="col-sm-6">
                                    </div>
                                </div>
                                <div class="form-group">
                                    <div class="col-sm-12">
                                        <div class="col-sm-2 control-label">相关线路：</div>
                                        <div class="col-sm-10">
                                            <select  class="form-control" id="line" multiple="multiple"
                                                    data-placeholder="选择线路"
                                                    style="width: 100%;">
                                            </select>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <div class="col-sm-12">
                                        <div class="col-sm-2 control-label">项目描述：</div>
                                        <div class="col-sm-10">
                                            <textarea name="" id="" cols="" rows="7"
                                                      v-model="projectEntity.projectDescribe" style="width: 100%"
                                                      name="projectDescribe"></textarea>
                                        </div>
                                    </div>
                                </div>
                                <div class="form-group">
                                    <div class="col-sm-2 control-label"></div>
                                    <a v-if="hasPermission('generator:projectentity:save')" class="btn btn-primary"
                                       @click="saveOrUpdate"><i class="fa fa-plus"></i>&nbsp;创建</a>
                                </div>
                            </form>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>

    <div v-show="!showList">
        <div class="row">
            <div class="col-xs-12">
                <div class="box box-primary">
                    <div class="box-body">
                        <div>
                            <div><h3 class="head-msg">项目概况 - <b class="subhead-msg"> {{projectName}} </b></h3></div>
                        </div>

                        <div class="operate-pane">
                            <a class="btn btn-primary" href="javascript:void(0)" @click="goDetails">保存</a>
                        </div>
                        <div class="container-fluid">
                            <table id="stage-table"></table>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>


<script src="../../libs/jquery.min.js"></script>
<script src="../../plugins/layer/layer.js"></script>
<script src="../../plugins/bootstrap/dist/js/bootstrap.min.js"></script>
<script src="../../plugins/bootstrap-table/dist/bootstrap-table.js"></script>
<script src="../../plugins/bootstrap-table/dist/extensions/treegrid/bootstrap-table-treegrid.min.js"></script>
<script src="../../plugins/bootstrap-treeview/dist/js/bootstrap-treeview.min.js"></script>
<script src="../../plugins/bootstrap-datetimepicker/dist/js/bootstrap-datetimepicker.min.js"></script>
<script src="../../plugins/bootstrap-datetimepicker/dist/js/locales/bootstrap-datetimepicker.zh-CN.js"
        charset="UTF-8"></script>
<script src="../../plugins/bootstrap-validator/dist/js/bootstrapValidator.min.js"></script>
<script src="../../plugins/jquery-treegrid/jquery.treegrid.min.js"></script>
<script src="../../libs/vue.min.js"></script>
<script src="../../plugins/jqgrid/grid.locale-cn.js"></script>
<script src="../../plugins/jqgrid/jquery.jqGrid.min.js"></script>
<script src="../../plugins/ztree/jquery.ztree.all.min.js"></script>
<script src="../../js/common.js"></script>
<!-- Select2 -->
<script src="../../plugins/select2/select2.min.js"></script>
<script src="../../js/modules/project/newproject.js"></script>

</body>
</html>